import request from "@/api/index"

export default {
  /**
   * @description: 添加摄像头 *代表必填
   * @param {Object} params *
   * @return {Object}
   */
  add(params) {
    const url = "/check/checkReport/add"
    return request.post(url, params)
  },
  /**
   * @description: 修改摄像头 *代表必填
   * @param {Object} params *
   * @return {Object}
   */
  edit(params) {
    const url = "/check/checkReport/edit"
    return request.post(url, params)
  },
  /**
   * @description: 单个删除摄像头 *代表必填
   * @param {String/Number} id *
   * @return {Object}
   */
  delById(params) {
    const url = "/check/checkReport/delById"
    return request.get(url, params)
  },
  /**
   * @description: 条件查询 *代表必填
   * @param {Object} params *
   * @return {Object}
   */
  queryByCondition(params) {
    const url = "/check/checkReport/queryByCondition"
    return request.post(url, params)
  },
  /**
   * @description: 分页查询摄像头 *代表必填
   * @param {Object} params *
   * @param {String/Number} page *
   * @param {String/Number} size *
   * @return {Object}
   */
  queryPageByCondition(params) {
    const url = "/check/checkReport/queryPageByCondition"
    return request.post(url, params)
  },
  /**
   * @description: 标识查询接口 *代表必填
   * @param {String/Number} id *
   * @return {Object}
   */
  queryByCompanyMark(params) {
    const url = "/check/platformCamera/queryByCompanyMark"
    return request.get(url, {
      companyMark: sessionStorage.getItem("companyMark")
    })
  },
  /**
   * @description: 标识查询接口 *代表必填
   * @param {String/Number} id *
   * @return {Object}
   */
  queryPageByConditionOMS(params) {
    const url = "/check/generalInspection/queryPageByCondition"
    return request.post(url, params)
  },
  /**
   * @description: 添加 *代表必填
   * @param {Object} params *
   * @return {Object}
   */
  addOMS(params){
    const url = "/check/generalInspection/add"
    return request.post(url, params)
  },
  /**
   * @description: 编辑 *代表必填
   * @param {Object} params *
   * @return {Object}
   */
  editOMS(params){
    const url = "/check/generalInspection/edit"
    return request.post(url, params)
  },
  /**
   * @description: 单个删除
   * @param {String/Number} id *
   * @return {Object}
   */
  delByIdOMS(params) {
    const url = "/check/generalInspection/delById"
    return request.get(url, params)
  },
}
